<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>InfdServerPool</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.0">
<link rel="home" href="index.html" title="libinfinity-0.4 Reference Manual">
<link rel="up" href="ch05.html" title="Libinfinity server side API">
<link rel="prev" href="InfdXmppServer.html" title="InfdXmppServer">
<link rel="next" href="ch06.html" title="Network abstraction">
<meta name="generator" content="GTK-Doc V1.15 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="InfdXmppServer.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="ch05.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">libinfinity-0.4 Reference Manual</th>
<td><a accesskey="n" href="ch06.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#InfdServerPool.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#InfdServerPool.description" class="shortcut">Description</a>
                   | 
                  <a href="#InfdServerPool.object-hierarchy" class="shortcut">Object Hierarchy</a>
                   | 
                  <a href="#InfdServerPool.properties" class="shortcut">Properties</a>
</td></tr>
</table>
<div class="refentry" title="InfdServerPool">
<a name="InfdServerPool"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="InfdServerPool.top_of_page"></a>InfdServerPool</span></h2>
<p>InfdServerPool</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv" title="Synopsis">
<a name="InfdServerPool.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis"><span class="returnvalue">void</span>                (<a class="link" href="InfdServerPool.html#InfdServerPoolForeachServerFunc" title="InfdServerPoolForeachServerFunc ()">*InfdServerPoolForeachServerFunc</a>)  (<em class="parameter"><code><a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> *server</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);
                    <a class="link" href="InfdServerPool.html#InfdServerPool-struct" title="InfdServerPool">InfdServerPool</a>;
                    <a class="link" href="InfdServerPool.html#InfdServerPoolClass" title="InfdServerPoolClass">InfdServerPoolClass</a>;
<a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="returnvalue">InfdServerPool</span></a> *    <a class="link" href="InfdServerPool.html#infd-server-pool-new" title="infd_server_pool_new ()">infd_server_pool_new</a>                (<em class="parameter"><code><a class="link" href="InfdDirectory.html" title="InfdDirectory"><span class="type">InfdDirectory</span></a> *directory</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="InfdServerPool.html#infd-server-pool-add-server" title="infd_server_pool_add_server ()">infd_server_pool_add_server</a>         (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> *server</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="InfdServerPool.html#infd-server-pool-add-local-publisher" title="infd_server_pool_add_local_publisher ()">infd_server_pool_add_local_publisher</a>
                                                        (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdXmppServer.html" title="InfdXmppServer"><span class="type">InfdXmppServer</span></a> *server</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfLocalPublisher.html" title="InfLocalPublisher"><span class="type">InfLocalPublisher</span></a> *publisher</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="InfdServerPool.html#infd-server-pool-remove-server" title="infd_server_pool_remove_server ()">infd_server_pool_remove_server</a>      (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> *server</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="InfdServerPool.html#infd-server-pool-foreach-server" title="infd_server_pool_foreach_server ()">infd_server_pool_foreach_server</a>     (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdServerPool.html#InfdServerPoolForeachServerFunc" title="InfdServerPoolForeachServerFunc ()"><span class="type">InfdServerPoolForeachServerFunc</span></a> func</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);
</pre>
</div>
<div class="refsect1" title="Object Hierarchy">
<a name="InfdServerPool.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----InfdServerPool
</pre>
</div>
<div class="refsect1" title="Properties">
<a name="InfdServerPool.properties"></a><h2>Properties</h2>
<pre class="synopsis">
  "<a class="link" href="InfdServerPool.html#InfdServerPool--directory" title='The "directory" property'>directory</a>"                <a class="link" href="InfdDirectory.html" title="InfdDirectory"><span class="type">InfdDirectory</span></a>*        : Read / Write / Construct Only
</pre>
</div>
<div class="refsect1" title="Description">
<a name="InfdServerPool.description"></a><h2>Description</h2>
<p>
</p>
</div>
<div class="refsect1" title="Details">
<a name="InfdServerPool.details"></a><h2>Details</h2>
<div class="refsect2" title="InfdServerPoolForeachServerFunc ()">
<a name="InfdServerPoolForeachServerFunc"></a><h3>InfdServerPoolForeachServerFunc ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                (*InfdServerPoolForeachServerFunc)  (<em class="parameter"><code><a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> *server</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>server</code></em> :</span></p></td>
<td>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="InfdServerPool">
<a name="InfdServerPool-struct"></a><h3>InfdServerPool</h3>
<pre class="programlisting">typedef struct _InfdServerPool InfdServerPool;</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2" title="InfdServerPoolClass">
<a name="InfdServerPoolClass"></a><h3>InfdServerPoolClass</h3>
<pre class="programlisting">typedef struct {
  GObjectClass parent_class;
} InfdServerPoolClass;
</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2" title="infd_server_pool_new ()">
<a name="infd-server-pool-new"></a><h3>infd_server_pool_new ()</h3>
<pre class="programlisting"><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="returnvalue">InfdServerPool</span></a> *    infd_server_pool_new                (<em class="parameter"><code><a class="link" href="InfdDirectory.html" title="InfdDirectory"><span class="type">InfdDirectory</span></a> *directory</code></em>);</pre>
<p>
Creates a new <a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>directory</code></em> :</span></p></td>
<td>A <a class="link" href="InfdDirectory.html" title="InfdDirectory"><span class="type">InfdDirectory</span></a> to which to add incoming connections.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> A new <a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="infd_server_pool_add_server ()">
<a name="infd-server-pool-add-server"></a><h3>infd_server_pool_add_server ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                infd_server_pool_add_server         (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> *server</code></em>);</pre>
<p>
Adds <em class="parameter"><code>server</code></em> to <em class="parameter"><code>server_pool</code></em>. The server pool accepts incoming connections
and gives them to its directory which processes incoming requests.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>server_pool</code></em> :</span></p></td>
<td>A <a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>server</code></em> :</span></p></td>
<td>A <a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="infd_server_pool_add_local_publisher ()">
<a name="infd-server-pool-add-local-publisher"></a><h3>infd_server_pool_add_local_publisher ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                infd_server_pool_add_local_publisher
                                                        (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdXmppServer.html" title="InfdXmppServer"><span class="type">InfdXmppServer</span></a> *server</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfLocalPublisher.html" title="InfLocalPublisher"><span class="type">InfLocalPublisher</span></a> *publisher</code></em>);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>server_pool</code></em> :</span></p></td>
<td>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>server</code></em> :</span></p></td>
<td>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>publisher</code></em> :</span></p></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="infd_server_pool_remove_server ()">
<a name="infd-server-pool-remove-server"></a><h3>infd_server_pool_remove_server ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                infd_server_pool_remove_server      (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> *server</code></em>);</pre>
<p>
Removed <em class="parameter"><code>server</code></em> from <em class="parameter"><code>servor_pool</code></em>. If <em class="parameter"><code>server</code></em> was published via
some publishers then it will be unpublished automatically.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>server_pool</code></em> :</span></p></td>
<td>A <a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>server</code></em> :</span></p></td>
<td>A <a class="link" href="InfdXmlServer.html" title="InfdXmlServer"><span class="type">InfdXmlServer</span></a> which was previously added to <em class="parameter"><code>server_pool</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="infd_server_pool_foreach_server ()">
<a name="infd-server-pool-foreach-server"></a><h3>infd_server_pool_foreach_server ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                infd_server_pool_foreach_server     (<em class="parameter"><code><a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a> *server_pool</code></em>,
                                                         <em class="parameter"><code><a class="link" href="InfdServerPool.html#InfdServerPoolForeachServerFunc" title="InfdServerPoolForeachServerFunc ()"><span class="type">InfdServerPoolForeachServerFunc</span></a> func</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre>
<p>
Calls <em class="parameter"><code>func</code></em> for each server in pool registered with
<a class="link" href="InfdServerPool.html#infd-server-pool-add-server" title="infd_server_pool_add_server ()"><code class="function">infd_server_pool_add_server()</code></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>server_pool</code></em> :</span></p></td>
<td>A <a class="link" href="InfdServerPool.html" title="InfdServerPool"><span class="type">InfdServerPool</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>func</code></em> :</span></p></td>
<td>The function to be called for each server.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
<td>Additional data to pass to <em class="parameter"><code>func</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
</div>
<div class="refsect1" title="Property Details">
<a name="InfdServerPool.property-details"></a><h2>Property Details</h2>
<div class="refsect2" title='The "directory" property'>
<a name="InfdServerPool--directory"></a><h3>The <code class="literal">"directory"</code> property</h3>
<pre class="programlisting">  "directory"                <a class="link" href="InfdDirectory.html" title="InfdDirectory"><span class="type">InfdDirectory</span></a>*        : Read / Write / Construct Only</pre>
<p>The directory to which to register incoming connections to.</p>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.15</div>
</body>
</html>